import { baseRequest } from '@/utils/request'

const request = (url, ...arg) => baseRequest(`/hwVehicle/hwvehiclegaslog/` + url, ...arg)

/**
 * 车辆每日油耗记录Api接口管理器
 *
 * @author cxk
 * @date  2023/09/11 18:11
 **/
export default {
	// 获取车辆每日油耗记录分页
	hwVehicleGasLogPage(data) {
		return request('page', data, 'get')
	},
	// 提交车辆每日油耗记录表单 edit为true时为编辑，默认为新增
	hwVehicleGasLogSubmitForm(data, edit = false) {
		return request(edit ? 'edit' : 'add', data)
	},
	// 删除车辆每日油耗记录
	hwVehicleGasLogDelete(data) {
		return request('delete', data)
	},
	// 获取车辆每日油耗记录详情
	hwVehicleGasLogDetail(data) {
		return request('detail', data, 'get')
	}}
